import com.demo.controller.DogBean2;
import com.demo.controller.DogBean3;
import com.demo.model.Dog;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: Admin
 * Date: 2023-02-12
 * Time: 17:18
 */
public class App2 {
    public static void main(String[] args) {

        ApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");

        DogBean2 dogBean2 = context.getBean("dogBean2", DogBean2.class);
        dogBean2.doDog();
        System.out.println();

        DogBean3 dogBean3 = context.getBean("dogBean3", DogBean3.class);
        dogBean3.doDog();

    }
}
